<?xml version='1.0' encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xml:lang="en" xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <link href="cpip.css" rel="stylesheet" type="text/css" />
    <title>File: /Users/paulross/dev/linux/linux-3.13/include/linux/dcache.h</title>
  </head>
  <body>
    <h1>File: /Users/paulross/dev/linux/linux-3.13/include/linux/dcache.h</h1>
    <p>Green shading in the line number column
means the source is part of the translation unit, red means it is conditionally excluded.
Highlighted line numbers link to the translation unit page. Highlighted macros link to
the macro page.</p>
    <pre><a name="1" /><span class="True">       1:</span> <span class="f">#</span><span class="n">ifndef</span> <a href="cpu.c_macros_noref.html#_X19MSU5VWF9EQ0FDSEVfSF8w"><span class="b">__LINUX_DCACHE_H</span></a>
<a name="2" /><span class="True">       2:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_X19MSU5VWF9EQ0FDSEVfSF8w"><span class="b">__LINUX_DCACHE_H</span></a>
<a name="3" /><span class="True">       3:</span> 
<a name="4" /><span class="True">       4:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">atomic</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="5" /><span class="True">       5:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">list</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="6" /><span class="True">       6:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">rculist</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="7" /><span class="True">       7:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">rculist_bl</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="8" /><span class="True">       8:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">spinlock</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="9" /><span class="True">       9:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">seqlock</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="10" /><span class="True">      10:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">cache</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="11" /><span class="True">      11:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">rcupdate</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="12" /><span class="True">      12:</span> <span class="f">#</span><span class="n">include</span> <span class="f">&lt;</span><span class="b">linux</span><span class="f">/</span><span class="b">lockref</span><span class="f">.</span><span class="b">h</span><span class="f">&gt;</span>
<a name="13" /><span class="True">      13:</span> 
<a name="14" /><span class="True">      14:</span> <span class="m">struct</span> <span class="b">nameidata</span><span class="f">;</span>
<a name="15" /><span class="True">      15:</span> <span class="m">struct</span> <span class="b">path</span><span class="f">;</span>
<a name="16" /><span class="True">      16:</span> <span class="m">struct</span> <span class="b">vfsmount</span><span class="f">;</span>
<a name="17" /><span class="True">      17:</span> 
<a name="18" /><span class="True">      18:</span> <span class="k">/*</span>
<a name="19" /><span class="True">      19:</span> <span class="k"> * linux/include/linux/dcache.h</span>
<a name="20" /><span class="True">      20:</span> <span class="k"> *</span>
<a name="21" /><span class="True">      21:</span> <span class="k"> * Dirent cache data structures</span>
<a name="22" /><span class="True">      22:</span> <span class="k"> *</span>
<a name="23" /><span class="True">      23:</span> <span class="k"> * (C) Copyright 1997 Thomas Schoebel-Theuer,</span>
<a name="24" /><span class="True">      24:</span> <span class="k"> * with heavy changes by Linus Torvalds</span>
<a name="25" /><span class="True">      25:</span> <span class="k"> */</span>
<a name="26" /><span class="True">      26:</span> 
<a name="27" /><span class="True">      27:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_SVNfUk9PVF8w"><span class="b">IS_ROOT</span></a><span class="f">(</span><span class="b">x</span><span class="f">)</span> <span class="f">(</span><span class="f">(</span><span class="b">x</span><span class="f">)</span> <span class="f">==</span> <span class="f">(</span><span class="b">x</span><span class="f">)</span><span class="f">-&gt;</span><span class="b">d_parent</span><span class="f">)</span>
<a name="28" /><span class="True">      28:</span> 
<a name="29" /><span class="True">      29:</span> <span class="k">/* The hash is always the low bits of hash_len */</span>
<a name="30" /><span class="True">      30:</span> <span class="f">#</span><span class="n">ifdef</span> <a href="cpu.c_macros_ref.html#_X19MSVRUTEVfRU5ESUFOXzA_"><span class="b">__LITTLE_ENDIAN</span></a>
<a name="31" /><span class="True">      31:</span>  <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_SEFTSF9MRU5fREVDTEFSRV8w"><span class="b">HASH_LEN_DECLARE</span></a> <a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a> <span class="b">hash</span><span class="f">;</span> <a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a> <span class="b">len</span><span class="f">;</span>
<a name="32" /><span class="True">      32:</span>  <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_Ynl0ZW1hc2tfZnJvbV9jb3VudF8w"><span class="b">bytemask_from_count</span></a><span class="f">(</span><span class="b">cnt</span><span class="f">)</span>    <span class="f">(</span><span class="f">~</span><span class="f">(</span><span class="f">~</span><span class="c">0ul</span> <span class="f">&lt;&lt;</span> <span class="f">(</span><span class="b">cnt</span><span class="f">)</span><span class="f">*</span><span class="c">8</span><span class="f">)</span><span class="f">)</span>
<a name="33" /><span class="False">      33:</span> <span class="f">#</span><span class="n">else</span>
<a name="34" /><span class="False">      34:</span>  <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_SEFTSF9MRU5fREVDTEFSRV8w"><span class="b">HASH_LEN_DECLARE</span></a> <a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a> <span class="b">len</span><span class="f">;</span> <a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a> <span class="b">hash</span><span class="f">;</span>
<a name="35" /><span class="False">      35:</span>  <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_Ynl0ZW1hc2tfZnJvbV9jb3VudF8w"><span class="b">bytemask_from_count</span></a><span class="f">(</span><span class="b">cnt</span><span class="f">)</span>    <span class="f">(</span><span class="f">~</span><span class="f">(</span><span class="f">~</span><span class="c">0ul</span> <span class="f">&gt;&gt;</span> <span class="f">(</span><span class="b">cnt</span><span class="f">)</span><span class="f">*</span><span class="c">8</span><span class="f">)</span><span class="f">)</span>
<a name="36" /><span class="True">      36:</span> <span class="f">#</span><span class="n">endif</span>
<a name="37" /><span class="True">      37:</span> 
<a name="38" /><span class="True">      38:</span> <span class="k">/*</span>
<a name="39" /><span class="True">      39:</span> <span class="k"> * &quot;quick string&quot; -- eases parameter passing, but more importantly</span>
<a name="40" /><span class="True">      40:</span> <span class="k"> * saves &quot;metadata&quot; about the string (ie length and the hash).</span>
<a name="41" /><span class="True">      41:</span> <span class="k"> *</span>
<a name="42" /><span class="True">      42:</span> <span class="k"> * hash comes first so it snuggles against d_parent in the</span>
<a name="43" /><span class="True">      43:</span> <span class="k"> * dentry.</span>
<a name="44" /><span class="True">      44:</span> <span class="k"> */</span>
<a name="45" /><span class="True">      45:</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">{</span>
<a name="46" /><span class="True">      46:</span>     <span class="m">union</span> <span class="f">{</span>
<a name="47" /><span class="True">      47:</span>         <span class="m">struct</span> <span class="f">{</span>
<a name="48" /><span class="True">      48:</span>             <a href="cpu.c_macros_ref.html#_SEFTSF9MRU5fREVDTEFSRV8w"><span class="b">HASH_LEN_DECLARE</span></a><span class="f">;</span>
<a name="49" /><span class="True">      49:</span>         <span class="f">}</span><span class="f">;</span>
<a name="50" /><span class="True">      50:</span>         <span class="b">u64</span> <span class="b">hash_len</span><span class="f">;</span>
<a name="51" /><span class="True">      51:</span>     <span class="f">}</span><span class="f">;</span>
<a name="52" /><span class="True">      52:</span>     <span class="m">const</span> <span class="m">unsigned</span> <span class="m">char</span> <span class="f">*</span><span class="b">name</span><span class="f">;</span>
<a name="53" /><span class="True">      53:</span> <span class="f">}</span><span class="f">;</span>
<a name="54" /><span class="True">      54:</span> 
<a name="55" /><span class="True">      55:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_UVNUUl9JTklUXzA_"><span class="b">QSTR_INIT</span></a><span class="f">(</span><span class="b">n</span><span class="f">,</span><span class="b">l</span><span class="f">)</span> <span class="f">{</span> <span class="f">{</span> <span class="f">{</span> <span class="f">.</span><span class="b">len</span> <span class="f">=</span> <span class="b">l</span> <span class="f">}</span> <span class="f">}</span><span class="f">,</span> <span class="f">.</span><span class="b">name</span> <span class="f">=</span> <span class="b">n</span> <span class="f">}</span>
<a name="56" /><span class="True">      56:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_aGFzaGxlbl9oYXNoXzA_"><span class="b">hashlen_hash</span></a><span class="f">(</span><span class="b">hashlen</span><span class="f">)</span> <span class="f">(</span><span class="f">(</span><a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a><span class="f">)</span> <span class="f">(</span><span class="b">hashlen</span><span class="f">)</span><span class="f">)</span>
<a name="57" /><span class="True">      57:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_aGFzaGxlbl9sZW5fMA__"><span class="b">hashlen_len</span></a><span class="f">(</span><span class="b">hashlen</span><span class="f">)</span>  <span class="f">(</span><span class="f">(</span><a href="cpu.c_macros_ref.html#_dTMyXzA_"><span class="b">u32</span></a><span class="f">)</span><span class="f">(</span><span class="f">(</span><span class="b">hashlen</span><span class="f">)</span> <span class="f">&gt;&gt;</span> <span class="c">32</span><span class="f">)</span><span class="f">)</span>
<a name="58" /><span class="True">      58:</span> 
<a name="59" /><span class="True">      59:</span> <span class="m">struct</span> <span class="b">dentry_stat_t</span> <span class="f">{</span>
<a name="60" /><span class="True">      60:</span>     <span class="m">long</span> <span class="b">nr_dentry</span><span class="f">;</span>
<a name="61" /><span class="True">      61:</span>     <span class="m">long</span> <span class="b">nr_unused</span><span class="f">;</span>
<a name="62" /><span class="True">      62:</span>     <span class="m">long</span> <span class="b">age_limit</span><span class="f">;</span>          <span class="k">/* age in seconds */</span>
<a name="63" /><span class="True">      63:</span>     <span class="m">long</span> <span class="b">want_pages</span><span class="f">;</span>         <span class="k">/* pages requested by system */</span>
<a name="64" /><span class="True">      64:</span>     <span class="m">long</span> <span class="b">dummy</span><span class="f">[</span><span class="c">2</span><span class="f">]</span><span class="f">;</span>
<a name="65" /><span class="True">      65:</span> <span class="f">}</span><span class="f">;</span>
<a name="66" /><span class="True">      66:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry_stat_t</span> <span class="b">dentry_stat</span><span class="f">;</span>
<a name="67" /><span class="True">      67:</span> 
<a name="68" /><span class="True">      68:</span> <span class="k">/* Name hashing routines. Initial hash value */</span>
<a name="69" /><span class="True">      69:</span> <span class="k">/* Hash courtesy of the R5 hash in reiserfs modulo sign bits */</span>
<a name="70" /><span class="True">      70:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_aW5pdF9uYW1lX2hhc2hfMA__"><span class="b">init_name_hash</span></a><span class="f">(</span><span class="f">)</span>        <span class="c">0</span>
<a name="71" /><span class="True">      71:</span> 
<a name="72" /><span class="True">      72:</span> <span class="k">/* partial hash update function. Assume roughly 4 bits per character */</span>
<a name="73" /><span class="True">      73:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">unsigned</span> <span class="m">long</span>
<a name="74" /><span class="True">      74:</span> <span class="b">partial_name_hash</span><span class="f">(</span><span class="m">unsigned</span> <span class="m">long</span> <span class="b">c</span><span class="f">,</span> <span class="m">unsigned</span> <span class="m">long</span> <span class="b">prevhash</span><span class="f">)</span>
<a name="75" /><span class="True">      75:</span> <span class="f">{</span>
<a name="76" /><span class="True">      76:</span>     <span class="m">return</span> <span class="f">(</span><span class="b">prevhash</span> <span class="f">+</span> <span class="f">(</span><span class="b">c</span> <span class="f">&lt;&lt;</span> <span class="c">4</span><span class="f">)</span> <span class="f">+</span> <span class="f">(</span><span class="b">c</span> <span class="f">&gt;&gt;</span> <span class="c">4</span><span class="f">)</span><span class="f">)</span> <span class="f">*</span> <span class="c">11</span><span class="f">;</span>
<a name="77" /><span class="True">      77:</span> <span class="f">}</span>
<a name="78" /><span class="True">      78:</span> 
<a name="79" /><span class="True">      79:</span> <span class="k">/*</span>
<a name="80" /><span class="True">      80:</span> <span class="k"> * Finally: cut down the number of bits to a int value (and try to avoid</span>
<a name="81" /><span class="True">      81:</span> <span class="k"> * losing bits)</span>
<a name="82" /><span class="True">      82:</span> <span class="k"> */</span>
<a name="83" /><span class="True">      83:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">unsigned</span> <span class="m">long</span> <span class="b">end_name_hash</span><span class="f">(</span><span class="m">unsigned</span> <span class="m">long</span> <span class="b">hash</span><span class="f">)</span>
<a name="84" /><span class="True">      84:</span> <span class="f">{</span>
<a name="85" /><span class="True">      85:</span>     <span class="m">return</span> <span class="f">(</span><span class="m">unsigned</span> <span class="m">int</span><span class="f">)</span> <span class="b">hash</span><span class="f">;</span>
<a name="86" /><span class="True">      86:</span> <span class="f">}</span>
<a name="87" /><span class="True">      87:</span> 
<a name="88" /><span class="True">      88:</span> <span class="k">/* Compute the hash for a name string. */</span>
<a name="89" /><span class="True">      89:</span> <span class="m">extern</span> <span class="m">unsigned</span> <span class="m">int</span> <span class="b">full_name_hash</span><span class="f">(</span><span class="m">const</span> <span class="m">unsigned</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">unsigned</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="90" /><span class="True">      90:</span> 
<a name="91" /><span class="True">      91:</span> <span class="k">/*</span>
<a name="92" /><span class="True">      92:</span> <span class="k"> * Try to keep struct dentry aligned on 64 byte cachelines (this will</span>
<a name="93" /><span class="True">      93:</span> <span class="k"> * give reasonable cacheline footprint with larger lines without the</span>
<a name="94" /><span class="True">      94:</span> <span class="k"> * large memory footprint increase).</span>
<a name="95" /><span class="True">      95:</span> <span class="k"> */</span>
<a name="96" /><span class="True">      96:</span> <span class="f">#</span><span class="n">ifdef</span> <a href="cpu.c_macros_ref.html#_Q09ORklHXzY0QklUXzA_"><span class="b">CONFIG_64BIT</span></a>
<a name="97" /><span class="True">      97:</span> <span class="f">#</span> <span class="n">define</span> <a href="cpu.c_macros_ref.html#_RE5BTUVfSU5MSU5FX0xFTl8w"><span class="b">DNAME_INLINE_LEN</span></a> <span class="c">32</span> <span class="k">/* 192 bytes */</span>
<a name="98" /><span class="False">      98:</span> <span class="f">#</span><span class="n">else</span>
<a name="99" /><span class="False">      99:</span> <span class="f">#</span> <span class="n">ifdef</span> <a href="cpu.c_macros_ref.html#_Q09ORklHX1NNUF8w"><span class="b">CONFIG_SMP</span></a>
<a name="100" /><span class="False">     100:</span> <span class="f">#</span>  <span class="n">define</span> <a href="cpu.c_macros_ref.html#_RE5BTUVfSU5MSU5FX0xFTl8w"><span class="b">DNAME_INLINE_LEN</span></a> <span class="c">36</span> <span class="k">/* 128 bytes */</span>
<a name="101" /><span class="False">     101:</span> <span class="f">#</span> <span class="n">else</span>
<a name="102" /><span class="False">     102:</span> <span class="f">#</span>  <span class="n">define</span> <a href="cpu.c_macros_ref.html#_RE5BTUVfSU5MSU5FX0xFTl8w"><span class="b">DNAME_INLINE_LEN</span></a> <span class="c">40</span> <span class="k">/* 128 bytes */</span>
<a name="103" /><span class="False">     103:</span> <span class="f">#</span> <span class="n">endif</span>
<a name="104" /><span class="True">     104:</span> <span class="f">#</span><span class="n">endif</span>
<a name="105" /><span class="True">     105:</span> 
<a name="106" /><span class="True">     106:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_ZF9sb2NrXzA_"><span class="b">d_lock</span></a>    <span class="b">d_lockref</span><span class="f">.</span><span class="b">lock</span>
<a name="107" /><span class="True">     107:</span> 
<a name="108" /><span class="True">     108:</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">{</span>
<a name="109" /><span class="True">     109:</span>     <span class="k">/* RCU lookup touched fields */</span>
<a name="110" /><span class="True">     110:</span>     <span class="m">unsigned</span> <span class="m">int</span> <span class="b">d_flags</span><span class="f">;</span>        <span class="k">/* protected by d_lock */</span>
<a name="111" /><span class="True">     111:</span>     <span class="b">seqcount_t</span> <span class="b">d_seq</span><span class="f">;</span>        <span class="k">/* per dentry seqlock */</span>
<a name="112" /><span class="True">     112:</span>     <span class="m">struct</span> <span class="b">hlist_bl_node</span> <span class="b">d_hash</span><span class="f">;</span>    <span class="k">/* lookup hash list */</span>
<a name="113" /><span class="True">     113:</span>     <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_parent</span><span class="f">;</span>    <span class="k">/* parent directory */</span>
<a name="114" /><span class="True">     114:</span>     <span class="m">struct</span> <span class="b">qstr</span> <span class="b">d_name</span><span class="f">;</span>
<a name="115" /><span class="True">     115:</span>     <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="b">d_inode</span><span class="f">;</span>        <span class="k">/* Where the name belongs to - NULL is</span>
<a name="116" /><span class="True">     116:</span> <span class="k">                     * negative */</span>
<a name="117" /><span class="True">     117:</span>     <span class="m">unsigned</span> <span class="m">char</span> <span class="b">d_iname</span><span class="f">[</span><a href="cpu.c_macros_ref.html#_RE5BTUVfSU5MSU5FX0xFTl8w"><span class="b">DNAME_INLINE_LEN</span></a><span class="f">]</span><span class="f">;</span>    <span class="k">/* small names */</span>
<a name="118" /><span class="True">     118:</span> 
<a name="119" /><span class="True">     119:</span>     <span class="k">/* Ref lookup also touches following */</span>
<a name="120" /><span class="True">     120:</span>     <span class="m">struct</span> <span class="b">lockref</span> <span class="b">d_lockref</span><span class="f">;</span>    <span class="k">/* per-dentry lock and refcount */</span>
<a name="121" /><span class="True">     121:</span>     <span class="m">const</span> <span class="m">struct</span> <span class="b">dentry_operations</span> <span class="f">*</span><span class="b">d_op</span><span class="f">;</span>
<a name="122" /><span class="True">     122:</span>     <span class="m">struct</span> <span class="b">super_block</span> <span class="f">*</span><span class="b">d_sb</span><span class="f">;</span>    <span class="k">/* The root of the dentry tree */</span>
<a name="123" /><span class="True">     123:</span>     <span class="m">unsigned</span> <span class="m">long</span> <span class="b">d_time</span><span class="f">;</span>        <span class="k">/* used by d_revalidate */</span>
<a name="124" /><span class="True">     124:</span>     <span class="m">void</span> <span class="f">*</span><span class="b">d_fsdata</span><span class="f">;</span>            <span class="k">/* fs-specific data */</span>
<a name="125" /><span class="True">     125:</span> 
<a name="126" /><span class="True">     126:</span>     <span class="m">struct</span> <span class="b">list_head</span> <span class="b">d_lru</span><span class="f">;</span>        <span class="k">/* LRU list */</span>
<a name="127" /><span class="True">     127:</span>     <span class="k">/*</span>
<a name="128" /><span class="True">     128:</span> <span class="k">     * d_child and d_rcu can share memory</span>
<a name="129" /><span class="True">     129:</span> <span class="k">     */</span>
<a name="130" /><span class="True">     130:</span>     <span class="m">union</span> <span class="f">{</span>
<a name="131" /><span class="True">     131:</span>         <span class="m">struct</span> <span class="b">list_head</span> <span class="b">d_child</span><span class="f">;</span>    <span class="k">/* child of parent list */</span>
<a name="132" /><span class="True">     132:</span>          <span class="m">struct</span> <a href="cpu.c_macros_ref.html#_cmN1X2hlYWRfMA__"><span class="b">rcu_head</span></a> <span class="b">d_rcu</span><span class="f">;</span>
<a name="133" /><span class="True">     133:</span>     <span class="f">}</span> <span class="b">d_u</span><span class="f">;</span>
<a name="134" /><span class="True">     134:</span>     <span class="m">struct</span> <span class="b">list_head</span> <span class="b">d_subdirs</span><span class="f">;</span>    <span class="k">/* our children */</span>
<a name="135" /><span class="True">     135:</span>     <span class="m">struct</span> <span class="b">hlist_node</span> <span class="b">d_alias</span><span class="f">;</span>    <span class="k">/* inode alias list */</span>
<a name="136" /><span class="True">     136:</span> <span class="f">}</span><span class="f">;</span>
<a name="137" /><span class="True">     137:</span> 
<a name="138" /><span class="True">     138:</span> <span class="k">/*</span>
<a name="139" /><span class="True">     139:</span> <span class="k"> * dentry-&gt;d_lock spinlock nesting subclasses:</span>
<a name="140" /><span class="True">     140:</span> <span class="k"> *</span>
<a name="141" /><span class="True">     141:</span> <span class="k"> * 0: normal</span>
<a name="142" /><span class="True">     142:</span> <span class="k"> * 1: nested</span>
<a name="143" /><span class="True">     143:</span> <span class="k"> */</span>
<a name="144" /><span class="True">     144:</span> <span class="m">enum</span> <span class="b">dentry_d_lock_class</span>
<a name="145" /><span class="True">     145:</span> <span class="f">{</span>
<a name="146" /><span class="True">     146:</span>     <span class="b">DENTRY_D_LOCK_NORMAL</span><span class="f">,</span> <span class="k">/* implicitly used by plain spin_lock() APIs. */</span>
<a name="147" /><span class="True">     147:</span>     <span class="b">DENTRY_D_LOCK_NESTED</span>
<a name="148" /><span class="True">     148:</span> <span class="f">}</span><span class="f">;</span>
<a name="149" /><span class="True">     149:</span> 
<a name="150" /><span class="True">     150:</span> <span class="m">struct</span> <span class="b">dentry_operations</span> <span class="f">{</span>
<a name="151" /><span class="True">     151:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_revalidate</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">unsigned</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="152" /><span class="True">     152:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_weak_revalidate</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">unsigned</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="153" /><span class="True">     153:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_hash</span><span class="f">)</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="154" /><span class="True">     154:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_compare</span><span class="f">)</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span>
<a name="155" /><span class="True">     155:</span>             <span class="m">unsigned</span> <span class="m">int</span><span class="f">,</span> <span class="m">const</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="156" /><span class="True">     156:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_delete</span><span class="f">)</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="157" /><span class="True">     157:</span>     <span class="m">void</span> <span class="f">(</span><span class="f">*</span><span class="b">d_release</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="158" /><span class="True">     158:</span>     <span class="m">void</span> <span class="f">(</span><span class="f">*</span><span class="b">d_prune</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="159" /><span class="True">     159:</span>     <span class="m">void</span> <span class="f">(</span><span class="f">*</span><span class="b">d_iput</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="160" /><span class="True">     160:</span>     <span class="m">char</span> <span class="f">*</span><span class="f">(</span><span class="f">*</span><span class="b">d_dname</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="161" /><span class="True">     161:</span>     <span class="m">struct</span> <span class="b">vfsmount</span> <span class="f">*</span><span class="f">(</span><span class="f">*</span><span class="b">d_automount</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">path</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="162" /><span class="True">     162:</span>     <span class="m">int</span> <span class="f">(</span><span class="f">*</span><span class="b">d_manage</span><span class="f">)</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">bool</span><span class="f">)</span><span class="f">;</span>
<a name="163" /><span class="True">     163:</span> <span class="f">}</span> <a href="cpu.c_macros_ref.html#_X19fX2NhY2hlbGluZV9hbGlnbmVkXzA_"><span class="b">____cacheline_aligned</span></a><span class="f">;</span>
<a name="164" /><span class="True">     164:</span> 
<a name="165" /><span class="True">     165:</span> <span class="k">/*</span>
<a name="166" /><span class="True">     166:</span> <span class="k"> * Locking rules for dentry_operations callbacks are to be found in</span>
<a name="167" /><span class="True">     167:</span> <span class="k"> * Documentation/filesystems/Locking. Keep it updated!</span>
<a name="168" /><span class="True">     168:</span> <span class="k"> *</span>
<a name="169" /><span class="True">     169:</span> <span class="k"> * FUrther descriptions are found in Documentation/filesystems/vfs.txt.</span>
<a name="170" /><span class="True">     170:</span> <span class="k"> * Keep it updated too!</span>
<a name="171" /><span class="True">     171:</span> <span class="k"> */</span>
<a name="172" /><span class="True">     172:</span> 
<a name="173" /><span class="True">     173:</span> <span class="k">/* d_flags entries */</span>
<a name="174" /><span class="True">     174:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX0hBU0hfMA__"><span class="b">DCACHE_OP_HASH</span></a>            <span class="c">0x00000001</span>
<a name="175" /><span class="True">     175:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX0NPTVBBUkVfMA__"><span class="b">DCACHE_OP_COMPARE</span></a>        <span class="c">0x00000002</span>
<a name="176" /><span class="True">     176:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX1JFVkFMSURBVEVfMA__"><span class="b">DCACHE_OP_REVALIDATE</span></a>        <span class="c">0x00000004</span>
<a name="177" /><span class="True">     177:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX0RFTEVURV8w"><span class="b">DCACHE_OP_DELETE</span></a>        <span class="c">0x00000008</span>
<a name="178" /><span class="True">     178:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX1BSVU5FXzA_"><span class="b">DCACHE_OP_PRUNE</span></a>            <span class="c">0x00000010</span>
<a name="179" /><span class="True">     179:</span> 
<a name="180" /><span class="True">     180:</span> <span class="f">#</span><span class="n">define</span>    <a href="cpu.c_macros_noref.html#_RENBQ0hFX0RJU0NPTk5FQ1RFRF8w"><span class="b">DCACHE_DISCONNECTED</span></a>        <span class="c">0x00000020</span>
<a name="181" /><span class="True">     181:</span>      <span class="k">/* This dentry is possibly not currently connected to the dcache tree, in</span>
<a name="182" /><span class="True">     182:</span> <span class="k">      * which case its parent will either be itself, or will have this flag as</span>
<a name="183" /><span class="True">     183:</span> <span class="k">      * well.  nfsd will not use a dentry with this bit set, but will first</span>
<a name="184" /><span class="True">     184:</span> <span class="k">      * endeavour to clear the bit either by discovering that it is connected,</span>
<a name="185" /><span class="True">     185:</span> <span class="k">      * or by performing lookup operations.   Any filesystem which supports</span>
<a name="186" /><span class="True">     186:</span> <span class="k">      * nfsd_operations MUST have a lookup function which, if it finds a</span>
<a name="187" /><span class="True">     187:</span> <span class="k">      * directory inode with a DCACHE_DISCONNECTED dentry, will d_move that</span>
<a name="188" /><span class="True">     188:</span> <span class="k">      * dentry into place and return that dentry rather than the passed one,</span>
<a name="189" /><span class="True">     189:</span> <span class="k">      * typically using d_splice_alias. */</span>
<a name="190" /><span class="True">     190:</span> 
<a name="191" /><span class="True">     191:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX1JFRkVSRU5DRURfMA__"><span class="b">DCACHE_REFERENCED</span></a>        <span class="c">0x00000040</span> <span class="k">/* Recently used, don&apos;t discard. */</span>
<a name="192" /><span class="True">     192:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX1JDVUFDQ0VTU18w"><span class="b">DCACHE_RCUACCESS</span></a>        <span class="c">0x00000080</span> <span class="k">/* Entry has ever been RCU-visible */</span>
<a name="193" /><span class="True">     193:</span> 
<a name="194" /><span class="True">     194:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0NBTlRfTU9VTlRfMA__"><span class="b">DCACHE_CANT_MOUNT</span></a>        <span class="c">0x00000100</span>
<a name="195" /><span class="True">     195:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX0dFTk9DSURFXzA_"><span class="b">DCACHE_GENOCIDE</span></a>            <span class="c">0x00000200</span>
<a name="196" /><span class="True">     196:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX1NIUklOS19MSVNUXzA_"><span class="b">DCACHE_SHRINK_LIST</span></a>        <span class="c">0x00000400</span>
<a name="197" /><span class="True">     197:</span> 
<a name="198" /><span class="True">     198:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX09QX1dFQUtfUkVWQUxJREFURV8w"><span class="b">DCACHE_OP_WEAK_REVALIDATE</span></a>    <span class="c">0x00000800</span>
<a name="199" /><span class="True">     199:</span> 
<a name="200" /><span class="True">     200:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX05GU0ZTX1JFTkFNRURfMA__"><span class="b">DCACHE_NFSFS_RENAMED</span></a>        <span class="c">0x00001000</span>
<a name="201" /><span class="True">     201:</span>      <span class="k">/* this dentry has been &quot;silly renamed&quot; and has to be deleted on the last</span>
<a name="202" /><span class="True">     202:</span> <span class="k">      * dput() */</span>
<a name="203" /><span class="True">     203:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX0NPT0tJRV8w"><span class="b">DCACHE_COOKIE</span></a>            <span class="c">0x00002000</span> <span class="k">/* For use by dcookie subsystem */</span>
<a name="204" /><span class="True">     204:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX0ZTTk9USUZZX1BBUkVOVF9XQVRDSEVEXzA_"><span class="b">DCACHE_FSNOTIFY_PARENT_WATCHED</span></a>    <span class="c">0x00004000</span>
<a name="205" /><span class="True">     205:</span>      <span class="k">/* Parent inode is watched by some fsnotify listener */</span>
<a name="206" /><span class="True">     206:</span> 
<a name="207" /><span class="True">     207:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX0RFTlRSWV9LSUxMRURfMA__"><span class="b">DCACHE_DENTRY_KILLED</span></a>        <span class="c">0x00008000</span>
<a name="208" /><span class="True">     208:</span> 
<a name="209" /><span class="True">     209:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01PVU5URURfMA__"><span class="b">DCACHE_MOUNTED</span></a>            <span class="c">0x00010000</span> <span class="k">/* is a mountpoint */</span>
<a name="210" /><span class="True">     210:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX05FRURfQVVUT01PVU5UXzA_"><span class="b">DCACHE_NEED_AUTOMOUNT</span></a>        <span class="c">0x00020000</span> <span class="k">/* handle automount on this dir */</span>
<a name="211" /><span class="True">     211:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01BTkFHRV9UUkFOU0lUXzA_"><span class="b">DCACHE_MANAGE_TRANSIT</span></a>        <span class="c">0x00040000</span> <span class="k">/* manage transit from this dirent */</span>
<a name="212" /><span class="True">     212:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01BTkFHRURfREVOVFJZXzA_"><span class="b">DCACHE_MANAGED_DENTRY</span></a> \
<a name="213" /><span class="True">     213:</span>     <span class="f">(</span><a href="cpu.c_macros_ref.html#_RENBQ0hFX01PVU5URURfMA__"><span class="b">DCACHE_MOUNTED</span></a><span class="f">|</span><a href="cpu.c_macros_ref.html#_RENBQ0hFX05FRURfQVVUT01PVU5UXzA_"><span class="b">DCACHE_NEED_AUTOMOUNT</span></a><span class="f">|</span><a href="cpu.c_macros_ref.html#_RENBQ0hFX01BTkFHRV9UUkFOU0lUXzA_"><span class="b">DCACHE_MANAGE_TRANSIT</span></a><span class="f">)</span>
<a name="214" /><span class="True">     214:</span> 
<a name="215" /><span class="True">     215:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_noref.html#_RENBQ0hFX0xSVV9MSVNUXzA_"><span class="b">DCACHE_LRU_LIST</span></a>            <span class="c">0x00080000</span>
<a name="216" /><span class="True">     216:</span> 
<a name="217" /><span class="True">     217:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0VOVFJZX1RZUEVfMA__"><span class="b">DCACHE_ENTRY_TYPE</span></a>        <span class="c">0x00700000</span>
<a name="218" /><span class="True">     218:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01JU1NfVFlQRV8w"><span class="b">DCACHE_MISS_TYPE</span></a>        <span class="c">0x00000000</span> <span class="k">/* Negative dentry */</span>
<a name="219" /><span class="True">     219:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0RJUkVDVE9SWV9UWVBFXzA_"><span class="b">DCACHE_DIRECTORY_TYPE</span></a>        <span class="c">0x00100000</span> <span class="k">/* Normal directory */</span>
<a name="220" /><span class="True">     220:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0FVVE9ESVJfVFlQRV8w"><span class="b">DCACHE_AUTODIR_TYPE</span></a>        <span class="c">0x00200000</span> <span class="k">/* Lookupless directory (presumed automount) */</span>
<a name="221" /><span class="True">     221:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX1NZTUxJTktfVFlQRV8w"><span class="b">DCACHE_SYMLINK_TYPE</span></a>        <span class="c">0x00300000</span> <span class="k">/* Symlink */</span>
<a name="222" /><span class="True">     222:</span> <span class="f">#</span><span class="n">define</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0ZJTEVfVFlQRV8w"><span class="b">DCACHE_FILE_TYPE</span></a>        <span class="c">0x00400000</span> <span class="k">/* Other file type */</span>
<a name="223" /><span class="True">     223:</span> 
<a name="224" /><span class="True">     224:</span> <span class="m">extern</span> <span class="b">seqlock_t</span> <span class="b">rename_lock</span><span class="f">;</span>
<a name="225" /><span class="True">     225:</span> 
<a name="226" /><span class="True">     226:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">int</span> <span class="b">dname_external</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="227" /><span class="True">     227:</span> <span class="f">{</span>
<a name="228" /><span class="True">     228:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_name</span><span class="f">.</span><span class="b">name</span> <span class="f">!=</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_iname</span><span class="f">;</span>
<a name="229" /><span class="True">     229:</span> <span class="f">}</span>
<a name="230" /><span class="True">     230:</span> 
<a name="231" /><span class="True">     231:</span> <span class="k">/*</span>
<a name="232" /><span class="True">     232:</span> <span class="k"> * These are the low-level FS interfaces to the dcache..</span>
<a name="233" /><span class="True">     233:</span> <span class="k"> */</span>
<a name="234" /><span class="True">     234:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_instantiate</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="235" /><span class="True">     235:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_instantiate_unique</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="236" /><span class="True">     236:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_materialise_unique</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="237" /><span class="True">     237:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">d_instantiate_no_diralias</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="238" /><span class="True">     238:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">__d_drop</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span><span class="f">;</span>
<a name="239" /><span class="True">     239:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_drop</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span><span class="f">;</span>
<a name="240" /><span class="True">     240:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_delete</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="241" /><span class="True">     241:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_set_d_op</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">dentry_operations</span> <span class="f">*</span><span class="b">op</span><span class="f">)</span><span class="f">;</span>
<a name="242" /><span class="True">     242:</span> 
<a name="243" /><span class="True">     243:</span> <span class="k">/* allocate/de-allocate */</span>
<a name="244" /><span class="True">     244:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_alloc</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="245" /><span class="True">     245:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_alloc_pseudo</span><span class="f">(</span><span class="m">struct</span> <span class="b">super_block</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="246" /><span class="True">     246:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_splice_alias</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="247" /><span class="True">     247:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_add_ci</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="248" /><span class="True">     248:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_find_any_alias</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="b">inode</span><span class="f">)</span><span class="f">;</span>
<a name="249" /><span class="True">     249:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_obtain_alias</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="250" /><span class="True">     250:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">shrink_dcache_sb</span><span class="f">(</span><span class="m">struct</span> <span class="b">super_block</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="251" /><span class="True">     251:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">shrink_dcache_parent</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="252" /><span class="True">     252:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">shrink_dcache_for_umount</span><span class="f">(</span><span class="m">struct</span> <span class="b">super_block</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="253" /><span class="True">     253:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">d_invalidate</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="254" /><span class="True">     254:</span> 
<a name="255" /><span class="True">     255:</span> <span class="k">/* only used at mount-time */</span>
<a name="256" /><span class="True">     256:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span> <span class="b">d_make_root</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="257" /><span class="True">     257:</span> 
<a name="258" /><span class="True">     258:</span> <span class="k">/* &lt;clickety&gt;-&lt;click&gt; the ramfs-type tree */</span>
<a name="259" /><span class="True">     259:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_genocide</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="260" /><span class="True">     260:</span> 
<a name="261" /><span class="True">     261:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_tmpfile</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="262" /><span class="True">     262:</span> 
<a name="263" /><span class="True">     263:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_find_alias</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="264" /><span class="True">     264:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_prune_aliases</span><span class="f">(</span><span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="265" /><span class="True">     265:</span> 
<a name="266" /><span class="True">     266:</span> <span class="k">/* test whether we have any submounts in a subdir tree */</span>
<a name="267" /><span class="True">     267:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">have_submounts</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="268" /><span class="True">     268:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">check_submounts_and_drop</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="269" /><span class="True">     269:</span> 
<a name="270" /><span class="True">     270:</span> <span class="k">/*</span>
<a name="271" /><span class="True">     271:</span> <span class="k"> * This adds the entry to the hash queues.</span>
<a name="272" /><span class="True">     272:</span> <span class="k"> */</span>
<a name="273" /><span class="True">     273:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_rehash</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="274" /><span class="True">     274:</span> 
<a name="275" /><span class="True">     275:</span> <span class="k">/**</span>
<a name="276" /><span class="True">     276:</span> <span class="k"> * d_add - add dentry to hash queues</span>
<a name="277" /><span class="True">     277:</span> <span class="k"> * @entry: dentry to add</span>
<a name="278" /><span class="True">     278:</span> <span class="k"> * @inode: The inode to attach to this dentry</span>
<a name="279" /><span class="True">     279:</span> <span class="k"> *</span>
<a name="280" /><span class="True">     280:</span> <span class="k"> * This adds the entry to the hash queues and initializes @inode.</span>
<a name="281" /><span class="True">     281:</span> <span class="k"> * The entry was actually filled in earlier during d_alloc().</span>
<a name="282" /><span class="True">     282:</span> <span class="k"> */</span>
<a name="283" /><span class="True">     283:</span>  
<a name="284" /><span class="True">     284:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">void</span> <span class="b">d_add</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">entry</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="b">inode</span><span class="f">)</span>
<a name="285" /><span class="True">     285:</span> <span class="f">{</span>
<a name="286" /><span class="True">     286:</span>     <span class="b">d_instantiate</span><span class="f">(</span><span class="b">entry</span><span class="f">,</span> <span class="b">inode</span><span class="f">)</span><span class="f">;</span>
<a name="287" /><span class="True">     287:</span>     <span class="b">d_rehash</span><span class="f">(</span><span class="b">entry</span><span class="f">)</span><span class="f">;</span>
<a name="288" /><span class="True">     288:</span> <span class="f">}</span>
<a name="289" /><span class="True">     289:</span> 
<a name="290" /><span class="True">     290:</span> <span class="k">/**</span>
<a name="291" /><span class="True">     291:</span> <span class="k"> * d_add_unique - add dentry to hash queues without aliasing</span>
<a name="292" /><span class="True">     292:</span> <span class="k"> * @entry: dentry to add</span>
<a name="293" /><span class="True">     293:</span> <span class="k"> * @inode: The inode to attach to this dentry</span>
<a name="294" /><span class="True">     294:</span> <span class="k"> *</span>
<a name="295" /><span class="True">     295:</span> <span class="k"> * This adds the entry to the hash queues and initializes @inode.</span>
<a name="296" /><span class="True">     296:</span> <span class="k"> * The entry was actually filled in earlier during d_alloc().</span>
<a name="297" /><span class="True">     297:</span> <span class="k"> */</span>
<a name="298" /><span class="True">     298:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_add_unique</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">entry</span><span class="f">,</span> <span class="m">struct</span> <span class="b">inode</span> <span class="f">*</span><span class="b">inode</span><span class="f">)</span>
<a name="299" /><span class="True">     299:</span> <span class="f">{</span>
<a name="300" /><span class="True">     300:</span>     <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">res</span><span class="f">;</span>
<a name="301" /><span class="True">     301:</span> 
<a name="302" /><span class="True">     302:</span>     <span class="b">res</span> <span class="f">=</span> <span class="b">d_instantiate_unique</span><span class="f">(</span><span class="b">entry</span><span class="f">,</span> <span class="b">inode</span><span class="f">)</span><span class="f">;</span>
<a name="303" /><span class="True">     303:</span>     <span class="b">d_rehash</span><span class="f">(</span><span class="b">res</span> <span class="f">!=</span> <a href="cpu.c_macros_ref.html#_TlVMTF8w"><span class="b">NULL</span></a> <span class="f">?</span> <span class="b">res</span> <span class="f">:</span> <span class="b">entry</span><span class="f">)</span><span class="f">;</span>
<a name="304" /><span class="True">     304:</span>     <span class="m">return</span> <span class="b">res</span><span class="f">;</span>
<a name="305" /><span class="True">     305:</span> <span class="f">}</span>
<a name="306" /><span class="True">     306:</span> 
<a name="307" /><span class="True">     307:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">dentry_update_name_case</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="308" /><span class="True">     308:</span> 
<a name="309" /><span class="True">     309:</span> <span class="k">/* used for rename() and baskets */</span>
<a name="310" /><span class="True">     310:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">d_move</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="311" /><span class="True">     311:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_ancestor</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="312" /><span class="True">     312:</span> 
<a name="313" /><span class="True">     313:</span> <span class="k">/* appendix may either be NULL or be used for transname suffixes */</span>
<a name="314" /><span class="True">     314:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_lookup</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="315" /><span class="True">     315:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">d_hash_and_lookup</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="316" /><span class="True">     316:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">__d_lookup</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="317" /><span class="True">     317:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">__d_lookup_rcu</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">parent</span><span class="f">,</span>
<a name="318" /><span class="True">     318:</span>                 <span class="m">const</span> <span class="m">struct</span> <span class="b">qstr</span> <span class="f">*</span><span class="b">name</span><span class="f">,</span> <span class="m">unsigned</span> <span class="f">*</span><span class="b">seq</span><span class="f">)</span><span class="f">;</span>
<a name="319" /><span class="True">     319:</span> 
<a name="320" /><span class="True">     320:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">unsigned</span> <span class="b">d_count</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="321" /><span class="True">     321:</span> <span class="f">{</span>
<a name="322" /><span class="True">     322:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_lockref</span><span class="f">.</span><span class="b">count</span><span class="f">;</span>
<a name="323" /><span class="True">     323:</span> <span class="f">}</span>
<a name="324" /><span class="True">     324:</span> 
<a name="325" /><span class="True">     325:</span> <span class="k">/* validate &quot;insecure&quot; dentry pointer */</span>
<a name="326" /><span class="True">     326:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">d_validate</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="327" /><span class="True">     327:</span> 
<a name="328" /><span class="True">     328:</span> <span class="k">/*</span>
<a name="329" /><span class="True">     329:</span> <span class="k"> * helper function for dentry_operations.d_dname() members</span>
<a name="330" /><span class="True">     330:</span> <span class="k"> */</span>
<a name="331" /><span class="True">     331:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">dynamic_dname</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">,</span> <span class="m">const</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="f">...</span><span class="f">)</span><span class="f">;</span>
<a name="332" /><span class="True">     332:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">simple_dname</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="333" /><span class="True">     333:</span> 
<a name="334" /><span class="True">     334:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">__d_path</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">path</span> <span class="f">*</span><span class="f">,</span> <span class="m">const</span> <span class="m">struct</span> <span class="b">path</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="335" /><span class="True">     335:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">d_absolute_path</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">path</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="336" /><span class="True">     336:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">d_path</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">path</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="337" /><span class="True">     337:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">dentry_path_raw</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="338" /><span class="True">     338:</span> <span class="m">extern</span> <span class="m">char</span> <span class="f">*</span><span class="b">dentry_path</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">,</span> <span class="m">char</span> <span class="f">*</span><span class="f">,</span> <span class="m">int</span><span class="f">)</span><span class="f">;</span>
<a name="339" /><span class="True">     339:</span> 
<a name="340" /><span class="True">     340:</span> <span class="k">/* Allocation counts.. */</span>
<a name="341" /><span class="True">     341:</span> 
<a name="342" /><span class="True">     342:</span> <span class="k">/**</span>
<a name="343" /><span class="True">     343:</span> <span class="k"> *    dget, dget_dlock -    get a reference to a dentry</span>
<a name="344" /><span class="True">     344:</span> <span class="k"> *    @dentry: dentry to get a reference to</span>
<a name="345" /><span class="True">     345:</span> <span class="k"> *</span>
<a name="346" /><span class="True">     346:</span> <span class="k"> *    Given a dentry or %NULL pointer increment the reference count</span>
<a name="347" /><span class="True">     347:</span> <span class="k"> *    if appropriate and return the dentry. A dentry will not be </span>
<a name="348" /><span class="True">     348:</span> <span class="k"> *    destroyed when it has references.</span>
<a name="349" /><span class="True">     349:</span> <span class="k"> */</span>
<a name="350" /><span class="True">     350:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dget_dlock</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="351" /><span class="True">     351:</span> <span class="f">{</span>
<a name="352" /><span class="True">     352:</span>     <span class="m">if</span> <span class="f">(</span><span class="b">dentry</span><span class="f">)</span>
<a name="353" /><span class="True">     353:</span>         <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_lockref</span><span class="f">.</span><span class="b">count</span><span class="f">++</span><span class="f">;</span>
<a name="354" /><span class="True">     354:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">;</span>
<a name="355" /><span class="True">     355:</span> <span class="f">}</span>
<a name="356" /><span class="True">     356:</span> 
<a name="357" /><span class="True">     357:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dget</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="358" /><span class="True">     358:</span> <span class="f">{</span>
<a name="359" /><span class="True">     359:</span>     <span class="m">if</span> <span class="f">(</span><span class="b">dentry</span><span class="f">)</span>
<a name="360" /><span class="True">     360:</span>         <span class="b">lockref_get</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_lockref</span><span class="f">)</span><span class="f">;</span>
<a name="361" /><span class="True">     361:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">;</span>
<a name="362" /><span class="True">     362:</span> <span class="f">}</span>
<a name="363" /><span class="True">     363:</span> 
<a name="364" /><span class="True">     364:</span> <span class="m">extern</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dget_parent</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span><span class="f">;</span>
<a name="365" /><span class="True">     365:</span> 
<a name="366" /><span class="True">     366:</span> <span class="k">/**</span>
<a name="367" /><span class="True">     367:</span> <span class="k"> *    d_unhashed -    is dentry hashed</span>
<a name="368" /><span class="True">     368:</span> <span class="k"> *    @dentry: entry to check</span>
<a name="369" /><span class="True">     369:</span> <span class="k"> *</span>
<a name="370" /><span class="True">     370:</span> <span class="k"> *    Returns true if the dentry passed is not currently hashed.</span>
<a name="371" /><span class="True">     371:</span> <span class="k"> */</span>
<a name="372" /><span class="True">     372:</span>  
<a name="373" /><span class="True">     373:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">int</span> <span class="b">d_unhashed</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="374" /><span class="True">     374:</span> <span class="f">{</span>
<a name="375" /><span class="True">     375:</span>     <span class="m">return</span> <span class="b">hlist_bl_unhashed</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_hash</span><span class="f">)</span><span class="f">;</span>
<a name="376" /><span class="True">     376:</span> <span class="f">}</span>
<a name="377" /><span class="True">     377:</span> 
<a name="378" /><span class="True">     378:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">int</span> <span class="b">d_unlinked</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="379" /><span class="True">     379:</span> <span class="f">{</span>
<a name="380" /><span class="True">     380:</span>     <span class="m">return</span> <span class="b">d_unhashed</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">&amp;&amp;</span> <span class="f">!</span><a href="cpu.c_macros_ref.html#_SVNfUk9PVF8w"><span class="b">IS_ROOT</span></a><span class="f">(</span><span class="b">dentry</span><span class="f">)</span><span class="f">;</span>
<a name="381" /><span class="True">     381:</span> <span class="f">}</span>
<a name="382" /><span class="True">     382:</span> 
<a name="383" /><span class="True">     383:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">int</span> <span class="b">cant_mount</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="384" /><span class="True">     384:</span> <span class="f">{</span>
<a name="385" /><span class="True">     385:</span>     <span class="m">return</span> <span class="f">(</span><span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">&amp;</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0NBTlRfTU9VTlRfMA__"><span class="b">DCACHE_CANT_MOUNT</span></a><span class="f">)</span><span class="f">;</span>
<a name="386" /><span class="True">     386:</span> <span class="f">}</span>
<a name="387" /><span class="True">     387:</span> 
<a name="388" /><span class="True">     388:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">void</span> <span class="b">dont_mount</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="389" /><span class="True">     389:</span> <span class="f">{</span>
<a name="390" /><span class="True">     390:</span>     <span class="b">spin_lock</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><a href="cpu.c_macros_ref.html#_ZF9sb2NrXzA_"><span class="b">d_lock</span></a><span class="f">)</span><span class="f">;</span>
<a name="391" /><span class="True">     391:</span>     <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">|=</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0NBTlRfTU9VTlRfMA__"><span class="b">DCACHE_CANT_MOUNT</span></a><span class="f">;</span>
<a name="392" /><span class="True">     392:</span>     <span class="b">spin_unlock</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><a href="cpu.c_macros_ref.html#_ZF9sb2NrXzA_"><span class="b">d_lock</span></a><span class="f">)</span><span class="f">;</span>
<a name="393" /><span class="True">     393:</span> <span class="f">}</span>
<a name="394" /><span class="True">     394:</span> 
<a name="395" /><span class="True">     395:</span> <span class="m">extern</span> <span class="m">void</span> <span class="b">dput</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="f">)</span><span class="f">;</span>
<a name="396" /><span class="True">     396:</span> 
<a name="397" /><span class="True">     397:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_managed</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="398" /><span class="True">     398:</span> <span class="f">{</span>
<a name="399" /><span class="True">     399:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">&amp;</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01BTkFHRURfREVOVFJZXzA_"><span class="b">DCACHE_MANAGED_DENTRY</span></a><span class="f">;</span>
<a name="400" /><span class="True">     400:</span> <span class="f">}</span>
<a name="401" /><span class="True">     401:</span> 
<a name="402" /><span class="True">     402:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_mountpoint</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="403" /><span class="True">     403:</span> <span class="f">{</span>
<a name="404" /><span class="True">     404:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">&amp;</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01PVU5URURfMA__"><span class="b">DCACHE_MOUNTED</span></a><span class="f">;</span>
<a name="405" /><span class="True">     405:</span> <span class="f">}</span>
<a name="406" /><span class="True">     406:</span> 
<a name="407" /><span class="True">     407:</span> <span class="k">/*</span>
<a name="408" /><span class="True">     408:</span> <span class="k"> * Directory cache entry type accessor functions.</span>
<a name="409" /><span class="True">     409:</span> <span class="k"> */</span>
<a name="410" /><span class="True">     410:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">void</span> <span class="b">__d_set_type</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">,</span> <span class="m">unsigned</span> <span class="b">type</span><span class="f">)</span>
<a name="411" /><span class="True">     411:</span> <span class="f">{</span>
<a name="412" /><span class="True">     412:</span>     <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">=</span> <span class="f">(</span><span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">&amp;</span> <span class="f">~</span><a href="cpu.c_macros_ref.html#_RENBQ0hFX0VOVFJZX1RZUEVfMA__"><span class="b">DCACHE_ENTRY_TYPE</span></a><span class="f">)</span> <span class="f">|</span> <span class="b">type</span><span class="f">;</span>
<a name="413" /><span class="True">     413:</span> <span class="f">}</span>
<a name="414" /><span class="True">     414:</span> 
<a name="415" /><span class="True">     415:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">void</span> <span class="b">__d_clear_type</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="416" /><span class="True">     416:</span> <span class="f">{</span>
<a name="417" /><span class="True">     417:</span>     <span class="b">__d_set_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">,</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01JU1NfVFlQRV8w"><span class="b">DCACHE_MISS_TYPE</span></a><span class="f">)</span><span class="f">;</span>
<a name="418" /><span class="True">     418:</span> <span class="f">}</span>
<a name="419" /><span class="True">     419:</span> 
<a name="420" /><span class="True">     420:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">void</span> <span class="b">d_set_type</span><span class="f">(</span><span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">,</span> <span class="m">unsigned</span> <span class="b">type</span><span class="f">)</span>
<a name="421" /><span class="True">     421:</span> <span class="f">{</span>
<a name="422" /><span class="True">     422:</span>     <span class="b">spin_lock</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><a href="cpu.c_macros_ref.html#_ZF9sb2NrXzA_"><span class="b">d_lock</span></a><span class="f">)</span><span class="f">;</span>
<a name="423" /><span class="True">     423:</span>     <span class="b">__d_set_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">,</span> <span class="b">type</span><span class="f">)</span><span class="f">;</span>
<a name="424" /><span class="True">     424:</span>     <span class="b">spin_unlock</span><span class="f">(</span><span class="f">&amp;</span><span class="b">dentry</span><span class="f">-&gt;</span><a href="cpu.c_macros_ref.html#_ZF9sb2NrXzA_"><span class="b">d_lock</span></a><span class="f">)</span><span class="f">;</span>
<a name="425" /><span class="True">     425:</span> <span class="f">}</span>
<a name="426" /><span class="True">     426:</span> 
<a name="427" /><span class="True">     427:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">unsigned</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="428" /><span class="True">     428:</span> <span class="f">{</span>
<a name="429" /><span class="True">     429:</span>     <span class="m">return</span> <span class="b">dentry</span><span class="f">-&gt;</span><span class="b">d_flags</span> <span class="f">&amp;</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0VOVFJZX1RZUEVfMA__"><span class="b">DCACHE_ENTRY_TYPE</span></a><span class="f">;</span>
<a name="430" /><span class="True">     430:</span> <span class="f">}</span>
<a name="431" /><span class="True">     431:</span> 
<a name="432" /><span class="True">     432:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_directory</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="433" /><span class="True">     433:</span> <span class="f">{</span>
<a name="434" /><span class="True">     434:</span>     <span class="m">return</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">==</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0RJUkVDVE9SWV9UWVBFXzA_"><span class="b">DCACHE_DIRECTORY_TYPE</span></a><span class="f">;</span>
<a name="435" /><span class="True">     435:</span> <span class="f">}</span>
<a name="436" /><span class="True">     436:</span> 
<a name="437" /><span class="True">     437:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_autodir</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="438" /><span class="True">     438:</span> <span class="f">{</span>
<a name="439" /><span class="True">     439:</span>     <span class="m">return</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">==</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0FVVE9ESVJfVFlQRV8w"><span class="b">DCACHE_AUTODIR_TYPE</span></a><span class="f">;</span>
<a name="440" /><span class="True">     440:</span> <span class="f">}</span>
<a name="441" /><span class="True">     441:</span> 
<a name="442" /><span class="True">     442:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_symlink</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="443" /><span class="True">     443:</span> <span class="f">{</span>
<a name="444" /><span class="True">     444:</span>     <span class="m">return</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">==</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX1NZTUxJTktfVFlQRV8w"><span class="b">DCACHE_SYMLINK_TYPE</span></a><span class="f">;</span>
<a name="445" /><span class="True">     445:</span> <span class="f">}</span>
<a name="446" /><span class="True">     446:</span> 
<a name="447" /><span class="True">     447:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_file</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="448" /><span class="True">     448:</span> <span class="f">{</span>
<a name="449" /><span class="True">     449:</span>     <span class="m">return</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">==</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX0ZJTEVfVFlQRV8w"><span class="b">DCACHE_FILE_TYPE</span></a><span class="f">;</span>
<a name="450" /><span class="True">     450:</span> <span class="f">}</span>
<a name="451" /><span class="True">     451:</span> 
<a name="452" /><span class="True">     452:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_negative</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="453" /><span class="True">     453:</span> <span class="f">{</span>
<a name="454" /><span class="True">     454:</span>     <span class="m">return</span> <span class="b">__d_entry_type</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span> <span class="f">==</span> <a href="cpu.c_macros_ref.html#_RENBQ0hFX01JU1NfVFlQRV8w"><span class="b">DCACHE_MISS_TYPE</span></a><span class="f">;</span>
<a name="455" /><span class="True">     455:</span> <span class="f">}</span>
<a name="456" /><span class="True">     456:</span> 
<a name="457" /><span class="True">     457:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">bool</span> <span class="b">d_is_positive</span><span class="f">(</span><span class="m">const</span> <span class="m">struct</span> <span class="b">dentry</span> <span class="f">*</span><span class="b">dentry</span><span class="f">)</span>
<a name="458" /><span class="True">     458:</span> <span class="f">{</span>
<a name="459" /><span class="True">     459:</span>     <span class="m">return</span> <span class="f">!</span><span class="b">d_is_negative</span><span class="f">(</span><span class="b">dentry</span><span class="f">)</span><span class="f">;</span>
<a name="460" /><span class="True">     460:</span> <span class="f">}</span>
<a name="461" /><span class="True">     461:</span> 
<a name="462" /><span class="True">     462:</span> <span class="m">extern</span> <span class="m">int</span> <span class="b">sysctl_vfs_cache_pressure</span><span class="f">;</span>
<a name="463" /><span class="True">     463:</span> 
<a name="464" /><span class="True">     464:</span> <span class="m">static</span> <span class="m">inline</span> <span class="m">unsigned</span> <span class="m">long</span> <span class="b">vfs_pressure_ratio</span><span class="f">(</span><span class="m">unsigned</span> <span class="m">long</span> <span class="b">val</span><span class="f">)</span>
<a name="465" /><span class="True">     465:</span> <span class="f">{</span>
<a name="466" /><span class="True">     466:</span>     <span class="m">return</span> <a href="cpu.c_macros_ref.html#_bXVsdF9mcmFjXzA_"><span class="b">mult_frac</span></a><span class="f">(</span><span class="b">val</span><span class="f">,</span> <span class="b">sysctl_vfs_cache_pressure</span><span class="f">,</span> <span class="c">100</span><span class="f">)</span><span class="f">;</span>
<a name="467" /><span class="True">     467:</span> <span class="f">}</span>
<a name="468" /><span class="True">     468:</span> <span class="f">#</span><span class="n">endif</span>    <span class="k">/* __LINUX_DCACHE_H */</span>
<a name="469" /><span class="True">     469:</span> </pre>
  </body>
</html>
